import request from '@/utils/request'

// 查询订单列表
export function listRefund(query) {
    return request({
        url: '/system/afterSale/list',
        method: 'get',
        params: query
    })
}

// 订单详情
export function searchRefund(id) {
    return request({
        url: `/system/afterSale/${id}`,
        method: 'get'
    })
}

// 处理售后信息
export function dealRefund(data) {
    return request({
        url: `/system/afterSale/processAfter/${data.afterSaleId}`,
        method: 'POST',
        params: data
    })
}


// 删除订单
export function delOrder(orderId) {
    return request({
        url: '/system/afterSale/' + orderId,
        method: 'delete'
    })
}